package com.stylefeng.guns.modular.pay.model;

import com.baomidou.mybatisplus.enums.IdType;
import java.util.Date;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableName;

import java.beans.Transient;
import java.io.Serializable;

/**
 * <p>
 * 通知记录表
 * </p>
 *
 * @author stylefeng
 * @since 2018-08-24
 */
@TableName("pay_notify_record")
public class NotifyRecord extends Model<NotifyRecord> {

    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;
    /**
     * VERSION
     */
    private Integer version;
    /**
     * 创建时间
     */
    @TableField("create_time")
    private Date createTime;
    /**
     * 最后一次通知时间
     */
    @TableField("last_notify_time")
    private Date lastNotifyTime;
    /**
     * 通知次数
     */
    @TableField("notify_times")
    private Integer notifyTimes;
    /**
     * 限制通知次数
     */
    @TableField("limit_notify_times")
    private Integer limitNotifyTimes;
    /**
     * 通知失败次数
     */
    @TableField("notify_fail_times")
    private Integer notifyFailTimes;
    /**
     * 商户编号
     */
    @TableField("merchant_no")
    private String merchantNo;
    /**
     * 商户订单号
     */
    @TableField("out_order_no")
    private String outOrderNo;
    @TableField("plat_trade_no")
    private String platTradeNo;
    /**
     * 通知状态(100:成功:101:未成功,默认101)
     */
    private Integer status;
    /**
     * 通知类型
     */
    @TableField("notify_type")
    private Integer notifyType;


    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Integer getVersion() {
        return version;
    }

    public void setVersion(Integer version) {
        this.version = version;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getLastNotifyTime() {
        return lastNotifyTime;
    }

    public void setLastNotifyTime(Date lastNotifyTime) {
        this.lastNotifyTime = lastNotifyTime;
    }

    public Integer getNotifyTimes() {
        return notifyTimes;
    }

    public void setNotifyTimes(Integer notifyTimes) {
        this.notifyTimes = notifyTimes;
    }

    public Integer getLimitNotifyTimes() {
        return limitNotifyTimes;
    }

    public void setLimitNotifyTimes(Integer limitNotifyTimes) {
        this.limitNotifyTimes = limitNotifyTimes;
    }

    public Integer getNotifyFailTimes() {
        return notifyFailTimes;
    }

    public void setNotifyFailTimes(Integer notifyFailTimes) {
        this.notifyFailTimes = notifyFailTimes;
    }

    public String getMerchantNo() {
        return merchantNo;
    }

    public void setMerchantNo(String merchantNo) {
        this.merchantNo = merchantNo;
    }

    public String getOutOrderNo() {
        return outOrderNo;
    }

    public void setOutOrderNo(String outOrderNo) {
        this.outOrderNo = outOrderNo;
    }

    public String getPlatTradeNo() {
        return platTradeNo;
    }

    public void setPlatTradeNo(String platTradeNo) {
        this.platTradeNo = platTradeNo;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Integer getNotifyType() {
        return notifyType;
    }

    public void setNotifyType(Integer notifyType) {
        this.notifyType = notifyType;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }
    
    //业务查询字段
    private String beginTime;
 
    private String endTime;
   
    @Transient
    public String getBeginTime() {
		return beginTime;
	}

	public void setBeginTime(String beginTime) {
		this.beginTime = beginTime;
	}
	@Transient
	public String getEndTime() {
		return endTime;
	}

	public void setEndTime(String endTime) {
		this.endTime = endTime;
	}

    @Override
    public String toString() {
        return "NotifyRecord{" +
        "id=" + id +
        ", version=" + version +
        ", createTime=" + createTime +
        ", lastNotifyTime=" + lastNotifyTime +
        ", notifyTimes=" + notifyTimes +
        ", limitNotifyTimes=" + limitNotifyTimes +
        ", notifyFailTimes=" + notifyFailTimes +
        ", merchantNo=" + merchantNo +
        ", outOrderNo=" + outOrderNo +
        ", platTradeNo=" + platTradeNo +
        ", status=" + status +
        ", notifyType=" + notifyType +
        "}";
    }
}
